<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>P216 9.4.1 RegExp类中的方法</title>
</head>

<body>
    <script>
        var reg = /([A-Z])([A-Z])\1\2/g;
        console.log(reg.test('1234'));
        console.log(reg.test('abab'));
        console.log(reg.test('CDCD'));
        console.log(reg.test('EfEf'));
        var reg1 = /[\s+]/g;
        console.log(reg1.exec('h i'));
        console.log(reg1.lastIndex);
        console.log(reg1.source);
        console.log(reg1.global);
        console.log(reg1.ignoreCase);
        console.log(reg1.multiline);
    </script>
    <a href="../首页/page09.html">
        <h2>返回上一页面</h2>
    </a>
</body>

</html>